/**
 * 
 */
package prj3;

/**
 * EarthCell extends SphericalCell and adds extra heating
 * and cooling
 * @author romain
 *
 */
public class EarthCell extends SphericalCell {

	/**
	 * Constructor with a default value
	 * @param grid
	 * @param coord
	 */
	public EarthCell(SphericalGrid grid, SphericalCoordinate coord) {
		super(grid, coord);
	}

	/**
	 * Constructor with a specified value
	 * @param grid
	 * @param coord
	 * @param _value
	 */
	public EarthCell(SphericalGrid grid, SphericalCoordinate coord, float _value) {
		super(grid, coord, _value);
	}

	/**
	 * Sets the amount of extra heating for this cell
	 * received from the sun.
	 * @param value
	 * @throws AssertionError if the cell is not mutable
	 */
	public void setExtraHeating(float value) {
		//if(this.mutable)
			extraHeating = value;
		//else
			//throw new AssertionError(!mutable);
	}
	
	/**
	 * Gets the amount of extra heating this 
	 * @return
	 */
	public float getExtraHeating() {
		return extraHeating;
	}

	/**
	 * Sets the cooling factor for all these
	 * cells (same cooling factor for all cells)
	 * @param value
	 */
	public static void setCooling(float value) {
		coolingFactor = value;
	}
	
	
	/**
	 * Gets the cooling factor for all these 
	 * cells
	 * @return float
	 */
	public static float getCooling() {
		return coolingFactor;
	}
	
	/* Protected variables */
	protected float extraHeating;
	protected static float coolingFactor;
}
